extends Resource
class_name EnemyItem
@export var enemyname : String
@export var score : int
@export var is_boss : bool = false
@export var current_level : int
@export var enemy_level : Array[EnemyLevelItem]

func _get(property: StringName) -> Variant:
	var item = enemy_level.get(current_level)
	if item :
		return item.get(property)
	return null

func _set(property: StringName, value: Variant) -> bool:
	if not enemy_level : return false
	var item : EnemyLevelItem = enemy_level.get(current_level)
	var param = item.get(property)
	if param == null : return false
	item.set(property, value)
	return true

func _init() -> void:
	set_local_to_scene(true)
